package com.ymttest.database.mapping.thirdpartysync;

import com.ymttest.database.model.thirdpartysync.fenqilecategory;
import com.ymttest.database.model.thirdpartysync.fenqilecategoryExample;
import java.util.List;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.DeleteProvider;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.InsertProvider;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.SelectProvider;
import org.apache.ibatis.annotations.Update;
import org.apache.ibatis.annotations.UpdateProvider;
import org.apache.ibatis.type.JdbcType;

public interface fenqilecategoryMapper {
    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table fenqilecategory
     *
     * @mbggenerated Mon Nov 04 15:21:13 CST 2019
     */
    @SelectProvider(type=fenqilecategorySqlProvider.class, method="countByExample")
    int countByExample(fenqilecategoryExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table fenqilecategory
     *
     * @mbggenerated Mon Nov 04 15:21:13 CST 2019
     */
    @DeleteProvider(type=fenqilecategorySqlProvider.class, method="deleteByExample")
    int deleteByExample(fenqilecategoryExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table fenqilecategory
     *
     * @mbggenerated Mon Nov 04 15:21:13 CST 2019
     */
    @Delete({
        "delete from fenqilecategory",
        "where Id = #{id,jdbcType=INTEGER}"
    })
    int deleteByPrimaryKey(Integer id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table fenqilecategory
     *
     * @mbggenerated Mon Nov 04 15:21:13 CST 2019
     */
    @Insert({
        "insert into fenqilecategory (Id, YmtCategory3Id, ",
        "FqlCategory1Id, FqlCategory2Id, ",
        "FqlCategory3Id, FqlCategory1Name, ",
        "FqlCategory2Name, FqlCategory3Name, ",
        "Commission, Action, ",
        "CreateTime, UpdateTime)",
        "values (#{id,jdbcType=INTEGER}, #{ymtCategory3Id,jdbcType=INTEGER}, ",
        "#{fqlCategory1Id,jdbcType=INTEGER}, #{fqlCategory2Id,jdbcType=INTEGER}, ",
        "#{fqlCategory3Id,jdbcType=INTEGER}, #{fqlCategory1Name,jdbcType=VARCHAR}, ",
        "#{fqlCategory2Name,jdbcType=VARCHAR}, #{fqlCategory3Name,jdbcType=VARCHAR}, ",
        "#{commission,jdbcType=DECIMAL}, #{action,jdbcType=INTEGER}, ",
        "#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP})"
    })
    int insert(fenqilecategory record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table fenqilecategory
     *
     * @mbggenerated Mon Nov 04 15:21:13 CST 2019
     */
    @InsertProvider(type=fenqilecategorySqlProvider.class, method="insertSelective")
    int insertSelective(fenqilecategory record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table fenqilecategory
     *
     * @mbggenerated Mon Nov 04 15:21:13 CST 2019
     */
    @SelectProvider(type=fenqilecategorySqlProvider.class, method="selectByExample")
    @Results({
        @Result(column="Id", property="id", jdbcType=JdbcType.INTEGER, id=true),
        @Result(column="YmtCategory3Id", property="ymtCategory3Id", jdbcType=JdbcType.INTEGER),
        @Result(column="FqlCategory1Id", property="fqlCategory1Id", jdbcType=JdbcType.INTEGER),
        @Result(column="FqlCategory2Id", property="fqlCategory2Id", jdbcType=JdbcType.INTEGER),
        @Result(column="FqlCategory3Id", property="fqlCategory3Id", jdbcType=JdbcType.INTEGER),
        @Result(column="FqlCategory1Name", property="fqlCategory1Name", jdbcType=JdbcType.VARCHAR),
        @Result(column="FqlCategory2Name", property="fqlCategory2Name", jdbcType=JdbcType.VARCHAR),
        @Result(column="FqlCategory3Name", property="fqlCategory3Name", jdbcType=JdbcType.VARCHAR),
        @Result(column="Commission", property="commission", jdbcType=JdbcType.DECIMAL),
        @Result(column="Action", property="action", jdbcType=JdbcType.INTEGER),
        @Result(column="CreateTime", property="createTime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="UpdateTime", property="updateTime", jdbcType=JdbcType.TIMESTAMP)
    })
    List<fenqilecategory> selectByExample(fenqilecategoryExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table fenqilecategory
     *
     * @mbggenerated Mon Nov 04 15:21:13 CST 2019
     */
    @Select({
        "select",
        "Id, YmtCategory3Id, FqlCategory1Id, FqlCategory2Id, FqlCategory3Id, FqlCategory1Name, ",
        "FqlCategory2Name, FqlCategory3Name, Commission, Action, CreateTime, UpdateTime",
        "from fenqilecategory",
        "where Id = #{id,jdbcType=INTEGER}"
    })
    @Results({
        @Result(column="Id", property="id", jdbcType=JdbcType.INTEGER, id=true),
        @Result(column="YmtCategory3Id", property="ymtCategory3Id", jdbcType=JdbcType.INTEGER),
        @Result(column="FqlCategory1Id", property="fqlCategory1Id", jdbcType=JdbcType.INTEGER),
        @Result(column="FqlCategory2Id", property="fqlCategory2Id", jdbcType=JdbcType.INTEGER),
        @Result(column="FqlCategory3Id", property="fqlCategory3Id", jdbcType=JdbcType.INTEGER),
        @Result(column="FqlCategory1Name", property="fqlCategory1Name", jdbcType=JdbcType.VARCHAR),
        @Result(column="FqlCategory2Name", property="fqlCategory2Name", jdbcType=JdbcType.VARCHAR),
        @Result(column="FqlCategory3Name", property="fqlCategory3Name", jdbcType=JdbcType.VARCHAR),
        @Result(column="Commission", property="commission", jdbcType=JdbcType.DECIMAL),
        @Result(column="Action", property="action", jdbcType=JdbcType.INTEGER),
        @Result(column="CreateTime", property="createTime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="UpdateTime", property="updateTime", jdbcType=JdbcType.TIMESTAMP)
    })
    fenqilecategory selectByPrimaryKey(Integer id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table fenqilecategory
     *
     * @mbggenerated Mon Nov 04 15:21:13 CST 2019
     */
    @UpdateProvider(type=fenqilecategorySqlProvider.class, method="updateByExampleSelective")
    int updateByExampleSelective(@Param("record") fenqilecategory record, @Param("example") fenqilecategoryExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table fenqilecategory
     *
     * @mbggenerated Mon Nov 04 15:21:13 CST 2019
     */
    @UpdateProvider(type=fenqilecategorySqlProvider.class, method="updateByExample")
    int updateByExample(@Param("record") fenqilecategory record, @Param("example") fenqilecategoryExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table fenqilecategory
     *
     * @mbggenerated Mon Nov 04 15:21:13 CST 2019
     */
    @UpdateProvider(type=fenqilecategorySqlProvider.class, method="updateByPrimaryKeySelective")
    int updateByPrimaryKeySelective(fenqilecategory record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table fenqilecategory
     *
     * @mbggenerated Mon Nov 04 15:21:13 CST 2019
     */
    @Update({
        "update fenqilecategory",
        "set YmtCategory3Id = #{ymtCategory3Id,jdbcType=INTEGER},",
          "FqlCategory1Id = #{fqlCategory1Id,jdbcType=INTEGER},",
          "FqlCategory2Id = #{fqlCategory2Id,jdbcType=INTEGER},",
          "FqlCategory3Id = #{fqlCategory3Id,jdbcType=INTEGER},",
          "FqlCategory1Name = #{fqlCategory1Name,jdbcType=VARCHAR},",
          "FqlCategory2Name = #{fqlCategory2Name,jdbcType=VARCHAR},",
          "FqlCategory3Name = #{fqlCategory3Name,jdbcType=VARCHAR},",
          "Commission = #{commission,jdbcType=DECIMAL},",
          "Action = #{action,jdbcType=INTEGER},",
          "CreateTime = #{createTime,jdbcType=TIMESTAMP},",
          "UpdateTime = #{updateTime,jdbcType=TIMESTAMP}",
        "where Id = #{id,jdbcType=INTEGER}"
    })
    int updateByPrimaryKey(fenqilecategory record);
}